# Maintainer: AndyRTR <andyrtr@archlinux.org>
# Contributor: Thomas Arnhold <thomas at arnhold dot org>

pkgname=liborcus
pkgver=0.17.2
pkgrel=5
pkgdesc="File import filter library for spreadsheet documents."
arch=('x86_64')
url="https://gitlab.com/orcus/orcus/blob/master/README.md"
license=('MPL')
depends=('libixion')
makedepends=('boost' 'mdds')
source=(https://kohei.us/files/orcus/src/${pkgname}-${pkgver}.tar.xz)
# https://gitlab.com/orcus/orcus/-/releases
sha256sums=('30509d414e3cf439e0ae1e0c31b4b0ef5b2bb8e2b2404e3cb7d44a72162640ab')

build() {
    cd "${pkgname}"-${pkgver}
    ./configure --prefix=/usr
    sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
    make
}

check() {
    cd "${pkgname}"-${pkgver}
    make check
}

package() {
    cd "${pkgname}"-${pkgver}
    make DESTDIR="$pkgdir" install
}
